 
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Konversi Kode HTML</title>
<style>
body {
		background: #fff;
		padding:20px;
		font:normal 11px Tahoma,Verdana,Arial,Sans-Serif;
		color:#999;
	}	
#textarea {background:rgba(87, 87, 87, 0.2) url('http://4.bp.blogspot.com/-dvVCIUylv3o/UmQ8KzeAOyI/AAAAAAAAIJs/ENvMx8x1kCc/s1600/icon4.png')no-repeat 95% 95%;background-size:70px 70px;width:94%;height:120px;color:Black;padding:10px;border-radius:5px;box-shadow:inset 0px 2px 6px rgba(0, 0, 0, 0.3);border:1px solid #ebebeb;}
#textarea:focus {background:rgba(87, 87, 87, 0.1)}
.tombol-textarea {padding:10px;box-shadow: 0px 1px 3px rgba(255, 255, 255, 0.5), inset 0px 1px 3px rgba(0, 0, 0, 0.2);margin:0 0 20px 0;text-align:center;border-radius:5px;width:94%;}
#convert,#clear {cursor: pointer;
padding: 3px 15px;
width: 100px;
border: 0;
background: rgba(247, 31, 28, 1);
box-shadow: 0 0 20px rgba(0,0,0,0.2) inset;
border-radius: 5px;
color: #fff;}
#convert,#clear:hover {
color: #fff;
background: rgba(247, 95, 28, 0.8);
}
</style>
<script src='https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js' type='text/javascript'></script>
</head>
<body>
<textarea id="textarea" placeholder="Masukan kode HTML lalu klik 'Convert'"></textarea>
<div class="tombol-textarea">
<button id="convert">Convert</button>
<button id="clear">Clear</button>
</div>
<script type='text/javascript'>
//<![CDATA[
$(function() {
    $('button#convert').click(function() {
        $('textarea#textarea').val(
        $('textarea#textarea').val()
            .replace(/&/g, "&amp;")
            .replace(/</g, "&lt;")
            .replace(/>/g, "&gt;")
            .replace(/"/g, "&quot;")
            .replace(/'/g, "&#39;")
            .replace(/^/, "<i rel=\"pre\">")
            .replace(/$/, "</i>")
        ).focus().select();
        return false;
    });
    $('button#clear').click(function() {
        $('textarea#textarea').val('').focus().select();
        return false;
    });
});
//]]>
</script>
<span>
  Powered by : <a href="http://problogiz.blogspot.com/"><b>Problogiz</b></a>
</span>
</body>
</html>